<?php
namespace app\helpers;
use Yii;

class Line{
    public static function send($mobile, $content) {
        $username = 'zzhysz'; //用户账号
        $password = '55823450'; //密码
        $content = iconv("UTF-8", "UTF-8", $content);
        $productid = 48661;  //产品id 配置信息
        $xh = '';  //留空
        $dstime = ''; //为空代表立即发送  如果加了时间代表定时发送
        $url = "http://www.ztsms.cn:8800/sendXSms.do?username=$username&password=$password&mobile=$mobile&content=$content&dstime=$dstime&productid=$productid&xh=$xh";
        $html = file_get_contents($url);
        return $html;
    }
}